package com.jbm.onehome.iface;

import javax.persistence.*;
import com.jbm.core.iface.IAcross;

/**
 * Created by lyh on 2017-03-22.
 */
@Entity
@Table(name = "otherconfig", schema = "", catalog = "")

public class OtherconfigEntity extends IAcross
{
	public OtherconfigEntity()
	{
		super();
	}

	public OtherconfigEntity(IAcross ia)
	{
		super(ia);
	}

    private static final long serialVersionUID = 9118151461515393805L;
    private int id;
    private String value;
    private Integer type;
    public   OtherconfigEntity(String method,Integer type,String value)
    {
        this.method=method;
        this.type=type;
        this.value=value;
    }
    @Id
    @Column(name = "id")
    @GeneratedValue
    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    @Basic
    @Column(name = "value")
    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }

    @Basic
    @Column(name = "type")
    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        OtherconfigEntity that = (OtherconfigEntity) o;

        if (id != that.id) return false;
        if (type != null ? !type.equals(that.type) : that.type != null) return false;
        if (value != null ? !value.equals(that.value) : that.value != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = id;
        result = 31 * result + (value != null ? value.hashCode() : 0);
        result = 31 * result + (type != null ? type.hashCode() : 0);
        return result;
    }

    @Transient
    public boolean back;
    @Transient
    public String method;
    @Transient
    public String errorinfo;
    @Transient
    public int count;
    @Transient
    public int start=0;
    @Transient
    public int pagesize=0;
    @Transient
    public Integer tableid;
}
